public class TaxDataModel extends Object implements XMLMarshallable
Java class specifies some specific tax settings that must configured in the tax settings of a subscriber account (in customer master data of the service provider);
These specific tax settings are adapted to each invoicing tax system supported by SAP Convergent Charging.
You can:
Note
This EZTax configuration data is related to an end customer of the service provider.
This EZTax data overrides the EZTax data which is pricing catalog of the service provider.
Tax settings are set at pricing catalog level in a charge customized
in an offer (see ChargeConditionModel) (or in a charge plan).
Refer to BillSoft EZTax product documentation for more information
about the role of this tax data.
TaxInfoModel,
SubscriberAccountModelThe XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="taxData">
<xs:complexType>
<xs:choice>
<xs:element name="eztaxData" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="name" type="xs:string"/>
<xs:attribute name="value" type="xs:string"/>
<xs:attribute name="type" type="TaxDataType" default="string"/>
</xs:complexType>
</xs:element>
<xs:element name="vatData" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="name" type="xs:string"/>
<xs:attribute name="value" type="xs:string"/>
<xs:attribute name="type" type="TaxDataType" default="string"/>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:complexType>
</xs:element><xs:simpleType name="TaxDataType">
<xs:restriction base="xs:string">
<xs:enumeration value="string"/>
<xs:enumeration value="number"/>
<xs:enumeration value="date"/>
</xs:restriction>
</xs:simpleType>
| Modifier and Type | Class and Description |
|---|---|
static class |
TaxDataModel.TaxDataType
This
enumeration lists the types |
static class |
TaxDataModel.Type
This
enumeration lists the type of tax data as string, number, or date. |
| Constructor and Description |
|---|
TaxDataModel()
Builds an empty tax data.
|
TaxDataModel(String taxDataStr)
Builds an empty tax data.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCharacterData(String cData)
Adds character data to the content element.
|
void |
addChild(String tagName,
XMLMarshallable child)
Adds a child to the object, the
child representing
the marshallable object which must be added to the element. |
void |
addEZTaxData(String name,
String value)
Sets a description associated with a language.
|
void |
addVatData(String name,
String value)
Sets a description associated with a language.
|
void |
clear()
Clears all descriptions associated with a language.
|
String |
getEZTaxData(String name)
Gets the description associated with the given language, if exists.
|
String |
getVatData(String name)
Gets the description associated with the given language, if exists.
|
boolean |
hasEZTaxData()
Returns true if the tax data is empty.
|
boolean |
hasVatData()
Returns true if the tax data is empty.
|
boolean |
isEmpty()
Returns true if the tax data is empty.
|
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, including its children.
|
void |
removeEZTaxData(String name)
Removes a description associated with a language.
|
void |
removeVatData(String name)
Removes a description associated with a language.
|
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being
processed.
|
String |
toString()
Returns a string representation of the tax data.
|
public TaxDataModel()
public TaxDataModel(String taxDataStr)
For VAT, the CSV string contains only values ordered as follows: VAT_CUSTOMER_COUNTRY_CODE; VAT_BUSINESS_CATEGORY
For EZTax, the CSV string contains only values ordered as follows: EZTAX_ORIGINATION; EZTAX_TERMINATION; EZTAX_SERVICE_ADDRESS; EZTAX_CUSTOMER_TYPE; EZTAX_RESALE_FLAG; EZTAX_INC_CODE
taxDataStr - A string that contains a tax data as a CSV stringpublic void addVatData(String name, String value)
name - The name of the tax datavalue - The value associated with the given tax datapublic void addEZTaxData(String name, String value)
name - The name of the tax datavalue - The value associated with the given tax datapublic void clear()
public void removeVatData(String name)
name - The name of the tax datapublic void removeEZTaxData(String name)
name - The name of the tax datapublic String getVatData(String name)
name - The name of the tax datapublic String getEZTaxData(String name)
name - The name of the tax datapublic boolean isEmpty()
public boolean hasVatData()
public boolean hasEZTaxData()
public String toString()
public void setAttributes(XMLAttributes atts)
XMLMarshallablesetAttributes in interface XMLMarshallableatts - The XML attributes of the current elementpublic void addChild(String tagName, XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.addChild in interface XMLMarshallabletagName - The name of tag for the childchild - The child to be addedpublic void addCharacterData(String cData)
XMLMarshallableaddCharacterData in interface XMLMarshallablecData - The character data to be addedpublic void marshal(XMLOutputter output)
XMLMarshallablemarshal in interface XMLMarshallableoutput - The XML output to marshal the object into